﻿@model IEnumerable<InfoLogic.Models.Person>

@*{
    ViewBag.Title = "Index";
}

<h2>Index</h2>

<p>
    @Html.ActionLink("Create New", "Create")
</p>
<table>
    <tr>
        <th>
            @Html.DisplayNameFor(model => model.FirstName)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.MiddleName)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.LastName)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.DOB)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Gender)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.UserName)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Contact.cellNumber)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Role.Description)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.UserPassword)
        </th>
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.FirstName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.MiddleName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.LastName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.DOB)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Gender)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.UserName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Contact.cellNumber)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Role.Description)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.UserPassword)
        </td>
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.PersonId }) |
            @Html.ActionLink("Details", "Details", new { id=item.PersonId }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.PersonId })
        </td>
    </tr>
}

</table>*@

<div>
    <p>The personal infomation has been successfully Saved</p>
    <p> 
              @Html.ActionLink("Next Step", "Create", "Address")
    </p>
</div>
